package com.dsl.dslallinone.common.config;

import javax.validation.constraints.NotBlank;

/**
 * 排序配置
 */
public class OrderConfig {
    @NotBlank(message = "排序字段不能为空")
    private String field;

    private String dir = "asc"; // asc, desc

    public OrderConfig() {}

    public OrderConfig(String field, String dir) {
        this.field = field;
        this.dir = dir;
    }

    // Getters and Setters
    public String getField() { return field; }
    public void setField(String field) { this.field = field; }
    public String getDir() { return dir; }
    public void setDir(String dir) { this.dir = dir; }
}
